<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@ include file="/msg.jsp"%>
<!DOCTYPE html>
<html>
	<head>
		<meta charset="UTF-8">
		<title>登录</title>
		<link rel="icon" href="${project_name}/image/logo.png" >
		<link rel="stylesheet" type="text/css" href="${project_name}/css/login.css"/>
	</head>
	<script src="https://cdn.dingxiang-inc.com/ctu-group/captcha-ui/index.js"></script>
	<script type="text/javascript" src="${project_name}/js/jquery-1.8.3.js"></script>
	<script>
		$(function () {
			var flag = false;
			var myCaptcha = _dx.Captcha(document.getElementById('yzm'), {
				appId: '05e4e0495b6bd88fda37ae0ead5d45f6', //appId，在控制台中“应用管理”或“应用配置”模块获取
				apiServer: '', // 请填写这个配置，按照下面“接入域名”所示!注意：末尾不要有斜杆！
				style: 'oneclick',
				width: '300',
				success: function (token) {
					flag = true
				}
			})
			//表单提交效验
			$('form').submit(function () {
				let no_internet = true
				if(!flag){
					if (no_internet) {
						return true;
					}
					layer.msg('请先通过滑动验证')
					return false;
				}
				return true;
			})
		})
	</script>
	<body>
		<div id="append"></div>
		<div class="full_sc">
			<div class="head_cent head_cwo ClearFix">
				<div class="h_logo">
					<a href="index.jsp">
						<img src="${project_name}/image/logo1.png"/>
					</a>
				</div>
				<div class="h_right">
					<img src="${project_name}/image/top_center.jpg"/>
				</div>
			</div>
		</div>
		<div class="w980 ClearFix">
			<div class="logo_box ClearFix">
				<div class="login_b_l ClearFix">
					<a href="" title="日光生活">
						<img style="width: 560px;height: 360px;" src="${project_name}/image/logo_img.jpg" alt="日光生活"/>
					</a>
				</div>
				<div class="login_b_r ClearFix">
					<div class="loginul ClearFix">
						<div class="login_h2 ClearFix">
							<h2>登录开心买</h2>
							<div class="lognrtop">
								还没有开心买账号<a href="register.jsp">快速注册</a>
							</div>
						</div>
						<div class="co">
							<div class="from">
								<form id="" action="${project_name}/users/login" method="post">
									<div class="item">
									<input class="itxt" name="username" placeholder="已验证手机/邮箱/用户名" value="" required>
									    <div class="err_box">
                                            <div class="err_msg2" style="display: none;">登录名可能是您的手机号、邮箱或用户名
                                            </div>
                                        </div>
									</div>
									<div class="item">
                                        <input class="itxt" placeholder="请输入密码" name="password" id="password" type="password" required>
                                        <div class="err_box">
                                            <div class="err_msg2" style="display: none;">您的密码可能为字母、数字或符号的组合</div>
                                        </div>
									</div>
									<div class="item" id="yzm">

									</div>
									<div class="item item4">
										<div class="safe ClearFix">
                                            <span>
                                            <input tabindex="4" class="jdcheckbox" name="autoLogin" id="autoLogin" checked="checked" type="checkbox">
                                            <label for="autoLogin">记住用户名</label>
                                            </span>
										</div>
									</div>
									<div class="item">
										<div class="login-btn">
                                            <a tabindex="6" onclick="$('form').submit()" id="loginsubmit" class="btn-img btn-entry" href="#">立即登录</a>
                                       </div>
									</div>
								</form>
							</div>
						</div>
					</div>
				</div>
			</div>
		</div>
	</body>
</html>
